home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 2 / CU Amiga Magazine's Super CD-ROM 02 (1996)(EMAP Images)(GB)[!][issue 1996-04].iso / magazine / amiga_e / setf.readme < prev    next >
Text File  |  1995-02-02  |  1KB  |  19 lines

  1. Short: Running E code from other processes
  2. Type: dev/e
  3. Uploader: m88jrh@uk.ac.ox.ecs (Jason R. Hulance)
  4. Author: m88jrh@uk.ac.ox.ecs (Jason R. Hulance)
  5.  
  6. This archive contains a few E sources which use SetFunction() to patch some
  7. library calls.  They serve to show how to run E code from other processes.
  8. The important point is that E uses the A4 register for its global variables
  9. so this must be preserved.  The examples show a running E program setting up
  10. a storage place for a copy of A4, and then code from this program can be run
  11. from another process (after first restoring A4).  The "other process" is the
  12. examples is the process which calls the patched system function.
  13.  
  14. Code which does not use global variables is easier to deal with, since this
  15. does not require restoration of A4.  However, a lot of code implicitly uses
  16. global variables, since things like library calls use the global library
  17. base variables.  Also, E built-in functions use a number of globals, e.g.,
  18. WriteF uses "stdout" and "conout".
  19.